package PriorityQueue;


import java.util.Comparator;
import java.util.PriorityQueue;

class Imp implements Comparator<Integer> {
    @Override
    public int compare(Integer o1,Integer o2) {
        return o2.compareTo(o1);
    }

}
public class Test {
    public static void main2(String[] args) {
        PriorityQueue<Integer> priorityQueue=new PriorityQueue<>(new Imp());
        priorityQueue.offer(15);
        priorityQueue.offer(8);
        priorityQueue.offer(9);
        priorityQueue.offer(24);
        priorityQueue.offer(36);
        System.out.println("-----");


    }
    public static void main(String[] args) {
        int[] arr = {25, 15, 23, 84, 56, 26, 48};
        MyPrioQueue myPrioQueue = new MyPrioQueue();
        myPrioQueue.itElem(arr);
        myPrioQueue.createBigHeap();
        myPrioQueue.HeapSort();
        //myPrioQueue.offer(90);
        //int s1=myPrioQueue.pop();
        //System.out.println(s1);
        System.out.println("-----");
    }
}
